﻿#region Header

/*
    This file is part of nDoctor Light

    NDoctor is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    NDoctor is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with NDoctor.  If not, see <http://www.gnu.org/licenses/>.
*/

#endregion Header

namespace Probel.Ldoc.Dal.Configuration
{
    using System;

    /// <summary>
    /// This interface is used to configure the repository with nHibernate
    /// </summary>
    public interface IDalManager
    {
        #region Methods

        /// <summary>
        /// This will configure the repository with nHibernate.
        /// </summary>
        /// <param name="fileName">Represents the path where the local DB is stored</param>
        /// <param name="createFreshDb">
        /// When set to <c>True</c>, it'll create a new fresh database and erase the old one if exists. 
        /// When set to <c>False</c>, it will load the specified database and not create a fresh one.
        /// When this parameter is ommitted, the previous database WILL NOT be deleted.</param>
        /// <returns></returns>
        DalManager ConfigureUsingFile(string fileName, bool createFreshDb = false);

        #endregion Methods
    }
}